<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <canvas id="box" width=400 height=400></canvas>
</body>
</html>
<script>
  let box = document.getElementById('box');
  let gl = box.getContext('webgl');
  console.log(gl)
  gl.clearColor(1.0,150/255.0,0.0,0.5) // 设置清空canvas的颜色
  gl.clear(gl.COLOR_BUFFER_BIT);
</script>